/** * @license * Copyright 2017 JBoss Inc * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ import { AfterViewInit, ChangeDetectorRef, ElementRef, EventEmitter, QueryList } from "@angular/core"; import { Document, ValidationProblem } from "apicurio-data-models"; import { SelectionService } from "../_services/selection.service"; import { CommandService } from "../_services/command.service"; import { AbstractBaseComponent } from "./common/base-component"; import { DocumentService } from "../_services/document.service"; /** * The component that models the editor's Title Bar. The title bar shows the title of the * API (and allows the title to be edited). It also shows the notification icon (the Bell icon) * which activates when there are validation problems detected. */ export declare class EditorTitleBarComponent extends AbstractBaseComponent implements AfterViewInit { private changeDetectorRef; private documentService; private selectionService; private commandService; document: Document; validationErrors: ValidationProblem[]; undoableCommandCount: number; redoableCommandCount: number; onUndoClick: EventEmitter; onRedoClick: EventEmitter; onConfigureValidation: EventEmitter; filterCriteria: string; showProblems: boolean; editMode: boolean; newTitle: string; titleInput: QueryList; constructor(changeDetectorRef: ChangeDetectorRef, documentService: DocumentService, selectionService: SelectionService, commandService: CommandService); ngAfterViewInit(): void; onInputKeypress(event: KeyboardEvent): void; editTitle(): void; cancel(): void; save(): void; isOAI30(): boolean; isAAI20(): boolean; isSwagger2(): boolean; /** * Called when the user selects the main/default element from the master area. */ selectMain(): void; /** * Returns the classes that should be applied to the "main" selection item. */ mainClasses(): string; /** * Returns true if the main node should be selected. */ isMainSelected(): boolean; /** * Called when the user clicks somewhere in the document. Used to close the context * menu if it is open. */ onDocumentClick(): void; /** * Returns the title of the API. */ title(): string; /** * Returns true if the API has a title. */ hasTitle(): boolean; /** * Called when the user clicks the Bell icon to show the list of problems. */ toggleProblemDrawer(): void; /** * Returns true if there are problems to report. */ private hasProblems; /** * Called to close the problem drawer. */ closeProblemDrawer(): void; }